function remoteCall(cmd, params, callback, timeoutCallback) {
	$.ajax({
		url: cmd,
		dataType: 'json',
		data: params,
		type: 'POST',
		success: function (resp) {
			if (window.console && window.console.log) {
				if (!resp)
					console.log('remoteCall(' + cmd + '): timeout')
				else if (resp.log)
					console.log(resp.log)
			}
			if (resp)
				callback(resp)
			else if (timeoutCallback)
				timeoutCallback()
		},
		timeout: null
	})
}

$(document).ready(function () {
	$.ys.menu.create('.ys-menu')
	$.ys.select.create('select')
	$.ys.datepicker.create('input.date')
})
